<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>伪类选择器</title>
    <style>
        /*
        匹配所有p标签中的第一个元素
        */
        p:first-child{
            color:red;
        }
        p>span:first-child{
            color: red;
        }
        p:first-child>span{
            font-size: 60px;
            color: red;
        }
    </style>
</head>
<body>
<!--first-child 匹配第一个伪类 -->
<p>白日依山尽</p>
<p>黄河入海流</p>
<hr>
<span>AAAAA</span> <br>
<p><span>bbbbb</span></p>
<p><span>ccccccc</span>dddddd<span>eeeeeeee</span></p>
</body>
</html>